Skip to content

Security: cross-tenant authz binding + ES256 pinning in JWT verify - #1

Merged
dukevuzz merged 2 commits into
mainfrom
fix/security-cross-tenant-authz
Sep 5, 2026
Merged

Security: cross-tenant authz binding + ES256 pinning in JWT verify#1
dukevuzz merged 2 commits into
mainfrom
fix/security-cross-tenant-authz

Conversation

@dukevuzz

Copy link
Copy Markdown
Contributor

Summary

Two security fixes to the JWT path:

  • Cross-tenant authz — api-key /validate binds to the token's projectId + scope, and the JWT issuer is enforced, so a token minted for one project can't be validated against another.
  • ES256 pinning (EXC-320)Verify now passes jwt.WithValidMethods(["ES256"]). A bare *SigningMethodECDSA type check still accepted ES384/ES512; this closes the remaining algorithm ambiguity.

Testing

go test ./internal/auth/ green, including a new regression test that asserts both an HS256-signed token (alg confusion, signed with a symmetric secret) and an alg:none token are rejected by the ES256-pinned verifier.

Context

Part of the Security Hardening epic (EXC-319). The matching verifier hardening on the data plane — ES256 pin + issuer binding in JwtService — is in excalibase-graphql PR #62. Provisioning's function verifier was already compliant (ES256 + iss + projectId↔path binding), so it needed no change.

https://claude.ai/code/session_01NEQh5YtRT9gfduicJiGJvu

@dukevuzz
dukevuzz merged commit cdbaf24 into main Sep 5, 2026
4 of 5 checks passed
@dukevuzz
dukevuzz deleted the fix/security-cross-tenant-authz branch September 5, 2026 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant